#include "interrupt_vector.h"

unsigned char sData1[]="RRRRRRR";
unsigned char cFlag=0;
// Timer 0 overflow interrupt service routine
interrupt [TIM0_OVF] void timer0_ovf_isr(void)
{
// Place your code here
}

// Timer1 output compare A interrupt service routine
interrupt [TIM1_COMPA] void timer1_compa_isr(void)
{
// Place your code here
    int iJarak = 0;        
    unsigned char sData[10];
    iJarak = fImReadPing();                                    
    sprintf(sData,"%d",iJarak);
    if(cFlag == 0)
    {
        lcd_gotoxy(1,1);
        lcd_puts(sData1);
    }
    else
    {
        lcd_gotoxy(1,1);
        lcd_puts(sData);
        cFlag = 0;
    }
}